package com.wjc.train.business.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.wjc.train.business.entity.TrainCarriage;
import com.wjc.train.business.req.TrainCarriageQueryReq;
import com.wjc.train.business.req.TrainCarriageSaveReq;
import com.wjc.train.business.resp.TrainCarriageQueryResp;

import java.util.List;

/**
 * <p>
 * 车厢表 服务类
 * </p>
 *
 * @author Guessed
 * @since 2023-08-02
 */
public interface ITrainCarriageService  {

  /**
     * 保存或修改
     * @param traincarriageSaveReq
     */
    void save(TrainCarriageSaveReq traincarriageSaveReq);

    /**
     * 分页查询
     * @param page
     * @param traincarriageQueryReq
     * @return
     */
    IPage<TrainCarriageQueryResp> queryList(IPage<TrainCarriageQueryResp> page, TrainCarriageQueryReq traincarriageQueryReq);

    /**
     * 删除
     * @param id
     */
    void delete(Long id);

  /**
   * 根据车次编号查询所有的车厢
   */
  List<TrainCarriage> queryByTrainCode(String trainCode);
}
